<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>

<body>
  <div class="box">Lorem ipsum dolor sit amet consectetur adipisicing elit. <strong>Impedit</strong> rerum dolore
    architecto.</div>

  <script>
    let box = document.querySelector(".box");
    console.log("box.innerHTML: ", box.innerHTML) //=>  Lorem ipsum dolor sit amet consectetur adipisicing elit. <strong>Impedit</strong> rerum dolore architecto.
    console.log("box.outerHTML: ", box.outerHTML) //=>  <div class="box">Lorem ipsum dolor sit amet consectetur adipisicing elit. <strong>Impedit</strong> rerum dolore architecto.</div>
  </script>

</body>

</html>